﻿using System;

using Fuse8.DomainFramework.Domain;

namespace Fuse8.DomainFramework.ValidationService
{
    /// <summary>
    /// 
    /// </summary>
    /// <typeparam name="TEntity"></typeparam>
    public interface IEntityValidationService<TEntity> where TEntity : class, IEntityObject
    {
        /// <summary>
        /// 
        /// </summary>
        /// <param name="entityObject"></param>
        /// <param name="actionType"></param>
        /// <returns></returns>
        ValidationResult Validate(TEntity entityObject, ValidationActionType actionType);

        /// <summary>
        /// 
        /// </summary>
        /// <param name="validator"></param>
        void SetSuccessor(IEntityValidationService<TEntity> validator);
    }
}
